﻿using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Drawing;
using System.Data;
using System.Linq;
using System.Text;
using System.Windows.Forms;

namespace GUI.UsersControls
{
    public partial class UcPanel : UserControl
    {
        public enum ongletIndex
        {
            ACCUEIL,
            BESOINS,
            ETUDES,
            MAINTENANCE
        }

        public String titre;
        public ongletIndex indexOnglet;
        public FormMain laFormMain { get { return ((FormMain)this.Parent); } }

        public UcPanel()
        {
            InitializeComponent();
            Visible = false;
            titre = "Ecran sans titre";
            indexOnglet = ongletIndex.BESOINS;
            Location = new Point(0, 96);

        }

        virtual public void afficher()
        {
            laFormMain.setTitre(titre);
            Visible = true;
        }

        virtual public void masquer()
        {
            Visible = false;
        }

        public void rageQuit()
        {
            Visible = false;
            laFormMain.afficherAccueil();
        }

    }
}
